<?php
/**
 * @var string $conetent 视图内容
 */
$time=time();
$interval=36;//12小时
header('Last-Modified: '.gmdate('r',$time));
header('Expires: '.gmdate('r',($time+$interval)));
header('Cache-Control: max-age='.$interval);
$levelInfo = \common\models\Common::getLevelsInfo(Yii::$app->user->identity->level);
$status = '';
// if (Yii::$app->user->identity->login_flag == 0) {
    $status = '<i class="fa fa-check" style="color:green;"></i>';
// } else {
//     if (Yii::$app->user->identity->login_flag == 2) {
//         $status = '<i class="fa fa-check" style="color:green;"></i>';
//     } else {
//         $status = '<i class="fa fa-close" style="color:red;"></i>';
//     }
// }

$clientSN = "管理员：" . Yii::$app->user->identity->loginName;
?>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <!-- Meta, title, CSS, favicons, etc. -->
    <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <META HTTP-EQUIV="pragma" CONTENT="no-cache"><!-- 禁止浏览器从本地计算机的缓存中访问页面内容 -->
    <META HTTP-EQUIV="Cache-Control" CONTENT="no-cache"><!-- 用于指定请求和响应遵循的缓存机制 -->
    <META HTTP-EQUIV="expires" CONTENT="0"><!-- 用于设定网页的到期时间，一旦网页过期，必须到服务器上重新传输； -->
    <title>天玺后台管理系统</title>

    <!-- Bootstrap -->
    <link href="/plugins/gentelella/vendors/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
    <!-- Font Awesome -->
    <link href="/plugins/gentelella/vendors/font-awesome/css/font-awesome.min.css" rel="stylesheet">
    <!-- NProgress -->
    <link href="/plugins/gentelella/vendors/nprogress/nprogress.css" rel="stylesheet">
    <!-- iCheck -->
    <link href="/plugins/gentelella/vendors/iCheck/skins/flat/green.css" rel="stylesheet">

    <!-- bootstrap-progressbar -->
    <link href="/plugins/gentelella/vendors/bootstrap-progressbar/css/bootstrap-progressbar-3.3.4.min.css"
          rel="stylesheet">
    <!-- JQVMap -->
    <link href="/plugins/gentelella/vendors/jqvmap/dist/jqvmap.min.css" rel="stylesheet"/>
    <!-- bootstrap-daterangepicker -->
    <link href="/plugins/gentelella/vendors/bootstrap-daterangepicker/daterangepicker.css" rel="stylesheet">
    <!-- jQuery custom content scroller -->
    <link href="/plugins/gentelella/vendors/malihu-custom-scrollbar-plugin/jquery.mCustomScrollbar.min.css"
          rel="stylesheet"/>

    <link href="/plugins/bootstrap-datepicker/css/bootstrap-datepicker3.min.css" rel="stylesheet"/>

    <!-- PNotify -->
    <link href="/plugins/gentelella/vendors/pnotify/dist/pnotify.css" rel="stylesheet">

    <!-- sweetalert2 -->
    <link href="/plugins/sweetalert2/sweetalert2.min.css" rel="stylesheet">


    <!-- Custom Theme Style -->
    <link href="/plugins/gentelella/build/css/custom.min.css" rel="stylesheet">

<!--    <link href="/css/fileinput.css" rel="stylesheet">-->
    <style>
        #sidebar-footer a {
            padding: 13px 0;
        }

        .nav.side-menu > li > a {
            font-weight: normal;
            font-size: 14px;
        }

        .nav.child_menu > li > a {
            font-weight: normal;
            font-size: 13px;
            padding: 10px;
        }

        .panel_toolbox {
            min-width: 0;
        }

        .btn, .buttons, .modal-footer .btn + .btn, button, .input-group, .form-group .btn {
            margin-bottom: 0;
        }

        table a {
            color: #058bb7;
        }

        table a:hover {
            color: #1bbdf1;
        }

        ul.bar_tabs > li.active {
            border-bottom: 1px solid white;
        }

        ul.bar_tabs {
            padding-left: 0;;
        }

        .panel-title {
            font-size: 14px;
            font-weight: 400;
        }

        .accordion .panel:hover {
            background: none;
        }

        .nav.side-menu > li.active, .nav.side-menu > li.current-page {
            border-right: none;
        }

        .nav-sm .nav.child_menu li.active, .nav-sm .nav.side-menu li.active-sm {
            border-right: none;
        }

    </style>
</head>

<body class="nav-md footer_fixed" style="background: #f7f7f7;">
<div class="container body">
    <div class="main_container">
        <div id="menu_fixed" class="col-md-3 left_col menu_fixed" style="z-index: 999">
            <div id="left_col" class="left_col scroll-view">
                <div class="navbar nav_title" style="border: 0;">
                    <a href="/" class="site_title">
                        <i class="fa fa-star"></i>
                        <span style="font-size: 16px;">天玺后台管理系统</span>
                    </a>
                </div>

                <div class="clearfix"></div>

                <!-- menu profile quick info -->
                <div class="profile clearfix">
                    <div class="profile_pic">
                        <img src="/images/default.png" alt="..." class="img-circle profile_img">
                    </div>
                    <div class="profile_info">
                        <span>
                            <?= $levelInfo['name'] . "  <small style='margin-left:10px;'>" . $status . "</small>"; ?>
                        </span>
                        <h2><?= $clientSN; ?></h2>
                    </div>
                </div>
                <!-- /menu profile quick info -->

                <br/>

                <!-- sidebar menu -->
                <div id="sidebar-menu" class="main_menu_side hidden-print main_menu">
                    <div class="menu_section" style="margin-bottom: 50px;">
                        <ul class="nav side-menu" id="side-menu">
                            <li class="text-center" style="padding: 120px 0;">
                                <img style="height: 50px;width: 50px;" src="/images/loading.gif"/>
                            </li>
                        </ul>
                    </div>
                </div>
                <!-- /sidebar menu -->

                <!-- /menu footer buttons -->
                <div id="sidebar-footer" class="sidebar-footer hidden-small">
                    <a data-toggle="tooltip"
                       data-placement="top"
                       title="首页"
                       href="javascript:void(0);"
                       onclick="$('#menu_11').find('a').trigger('click');">
                        <span class="glyphicon glyphicon-home" aria-hidden="true"></span>
                    </a>

                    <a data-toggle="tooltip"
                       data-placement="top"
                       title="终端客户"
                       href="javascript:void(0);"
                       onclick="$('#menu_13').find('a').trigger('click');">
                        <span class="glyphicon glyphicon-globe" aria-hidden="true"></span>
                    </a>

                    <a data-toggle="tooltip"
                       data-placement="top"
                       title="个人中心"
                       href="javascript:void(0);"
                       onclick="$('#menu_1').find('a').trigger('click');">
                        <span class="glyphicon glyphicon-user" aria-hidden="true"></span>
                    </a>

                    <a data-toggle="tooltip"
                       data-placement="top"
                       title="安全退出"
                       href="javascript:void(0)"
                       onclick="logout()">
                        <span class="glyphicon glyphicon-off" aria-hidden="true"></span>
                    </a>
                </div>
                <!-- /menu footer buttons -->
            </div>
        </div>

        <!-- top navigation -->
        <div class="top_nav">
            <div id="nav_menu" class="nav_menu">
                <nav>
                    <div class="nav toggle">
                        <a id="menu_toggle"><i class="fa fa-bars"></i></a>
                    </div>

                    <ul class="nav navbar-nav navbar-right">
                        <li class="">
                            <a href="javascript:void(0);"
                               class="user-profile dropdown-toggle"
                               data-toggle="dropdown"
                               aria-expanded="false">
                                <img src="/images/default.png" alt=""><?= $clientSN; ?>
                            </a>
                        </li>
                    </ul>
                </nav>
            </div>
        </div>
        <!-- /top navigation -->

        <!-- page content -->
        <div id="right_col" class="right_col" role="main">
            <?= $content ?>
        </div>
        <!-- /page content -->

        <!-- footer content -->
        <footer id="footer" style="border-top: 1px solid #D9DEE4;background: #EDEDED;z-index: 998;">
            <div class="pull-right">
                &copy; 2018-<?= date('Y'); ?> All Rights Reserved.
            </div>
            <div class="clearfix"></div>
        </footer>
        <!-- /footer content -->
    </div>

    <!--带操作按钮-->
    <div class="modal fade" id="modal_pop" data-backdrop="static" data-keyboard="false">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                        <span aria-hidden="true">&times;</span>
                    </button>
                    <h5 class="modal-title"><i id="modal_pop_title"></i></h5>
                </div>
                <div class="modal-body" id="modal_pop_body"></div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal">关 闭</button>
                    <button type="button" class="btn btn-primary" id="modal_pop_btn">提 交</button>
                </div>
            </div>
        </div>
    </div>

    <!--带操作按钮的大弹出框-->
    <div class="modal fade" id="modal_lg_pop" data-backdrop="static" data-keyboard="false">
        <div class="modal-dialog modal-lg">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                        <span aria-hidden="true">&times;</span>
                    </button>
                    <h5 class="modal-title"><i id="modal_lg_pop_title"></i></h5>
                </div>
                <div class="modal-body" id="modal_lg_pop_body"></div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal">关 闭</button>
                    <button type="button" class="btn btn-primary" id="modal_lg_pop_btn">提 交</button>
                </div>
            </div>
        </div>
    </div>

    <!--不带操作按钮-->
    <div class="modal fade" id="modal_pop2" data-backdrop="static" data-keyboard="false">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                        <span aria-hidden="true">&times;</span>
                    </button>
                    <h5 class="modal-title"><i id="modal_pop2_title"></i></h5>
                </div>
                <div class="modal-body" id="modal_pop2_body"></div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal">关 闭</button>
                </div>
            </div>
        </div>
    </div>
</div>

<!-- jQuery -->
<script src="/plugins/gentelella/vendors/jquery/dist/jquery.min.js"></script>
<script type="text/javascript" src="/plugins/atlant/js/actions.js"></script>
<!-- Bootstrap -->
<script src="/plugins/gentelella/vendors/bootstrap/dist/js/bootstrap.min.js"></script>
<!-- bootstrap-daterangepicker -->
<script src="/plugins/gentelella/vendors/moment/min/moment.min.js"></script>
<script src="/plugins/gentelella/vendors/bootstrap-daterangepicker/daterangepicker.js"></script>
<!-- jQuery custom content scroller -->
<script src="/plugins/gentelella/vendors/malihu-custom-scrollbar-plugin/jquery.mCustomScrollbar.concat.min.js"></script>
<script src="/plugins/bootstrap-datepicker/js/bootstrap-datepicker.min.js"></script>
<!-- PNotify -->
<script src="/plugins/gentelella/vendors/pnotify/dist/pnotify.js"></script>
<!-- sweetalert2 -->
<script src="/plugins/sweetalert2/sweetalert2.min.js"></script>
<script src="/plugins/QRCode/qrcode.min.js"></script>
<script src="/plugins/clipboard/clipboard.min.js"></script>
<script src="/js/fileinput.js"></script>
<script src="/js/zh.js"></script>
<script src="/plugins/clipboard/clipboard.min.js"></script>
<script src="/js/main.js?v=<?= Yii::$app->params['version']; ?>"></script>
<script src="/js/menu.js?v=<?= Yii::$app->params['version']; ?>"></script>
<script src="/js/trader.js?v=<?= Yii::$app->params['version']; ?>"></script>
<script src="/js/agent.js?v=<?= Yii::$app->params['version']; ?>"></script>
<script src="/js/money.js?v=<?= Yii::$app->params['version']; ?>"></script>
<script src="/js/tradeCostReturn.js?v=<?= Yii::$app->params['version']; ?>"></script>
<script src="/js/realNameCheck.js?v=<?= Yii::$app->params['version']; ?>"></script>
<script src="/js/recharge.js?v=<?= Yii::$app->params['version']; ?>"></script>
</body>
</html>
